<?php
namespace app\common\model;
use x\Xbase;
class Reply extends Xbase
{
    /**
     * 删除回复
     * @param  [type] $id [description]
     * @return [type]     [description]
     */
    public function del($id){
        $ids = is_array($id) ? $id : [$id];
        foreach($ids as $id){
            $this->db->delete('reply',$id);
            $this->db->query("delete from dianzan where `table`='reply' and table_id=?",[$id]);
            m('Attachment','xcom')->imgDel('reply',$id,true);
        }
        return true;
    }
}
